package com.dingwen.treasure.auth.controller;

import com.dingwen.treasure.auth.feign.TreasureManageFeignClient;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * 　ManageFeignController: 模拟远程调用 manage 进行登录接口 （目前问题： 登录信息返回、用户锁定等功能不方便实现）
 * 　@author dingwen
 * 　@date 2022/6/25
 */
@Api(tags = "模拟远程调用 manage 进行登录接口")
@RestController
@RequestMapping("feign")
public class ManageFeignController {

    /**
     * treasureManageFeignClient
     */
    @Resource
    private TreasureManageFeignClient treasureManageFeignClient;

    @ApiOperation(value = "测试")
    @GetMapping()
    public void test() {
        treasureManageFeignClient.getOneByAccount("dingwen");
        treasureManageFeignClient.getSysMenusForTree(4L);
        treasureManageFeignClient.getSysElementsByUserId(4L);
        treasureManageFeignClient.getSysMenusByUserId(4L);
    }
}
